#include "CCharJobInfoPacket.h"
#include "CChar.h"

CCharJobInfoPacket::CCharJobInfoPacket(CChar * schar) {
	this->type = 0x1B;
	this->size = 0x32;

	memset(this->data, 0, sizeof(data));

	schar->j.reserved = (unsigned char)(schar->j.unlocked >> 16);

	memcpy(&this->data[0x04-4], &(schar->l.race), 1);
	memcpy(&this->data[0x08-4], &(schar->m_jobMain), 1);
	memcpy(&this->data[0x0B-4], &(schar->m_jobSub), 1);
	memcpy(&this->data[0x0C-4], &(schar->j), 20);
	memcpy(&this->data[0x20-4], &(schar->stats.str), 28);
	memcpy(&this->data[0x3C-4], &(schar->h.hp), 2);
	memcpy(&this->data[0x40-4], &(schar->h.mp), 2);
	memcpy(&this->data[0x44-4], &(schar->j), sizeof(schar->j));
	memcpy(&this->data[0x44-4], &(schar->m_subjobUnlocked), 4);
}

CCharJobInfoPacket::~CCharJobInfoPacket() {

}

